package com.chenjt.jvm.first.five_heap;

import java.util.ArrayList;
import java.util.Random;

/**
 * 注释：
 * -Xms600m -Xmx600m
 *
 * @author chenjt
 * @date 2025/6/9 10:07
 */
public class HeapInstanceTest {

    byte[] buffer = new byte[new Random().nextInt(1024 * 200)];

    public static void main(String[] args) {
        ArrayList<HeapInstanceTest> list = new ArrayList<>();

        while (true){
            list.add(new HeapInstanceTest());
            try {
                Thread.sleep(10);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
        }

    }


}
